<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.org/ui"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:c="http://java.sun.com/jsp/jstl/core">
    
    <body>
        <h:form> 
        <p:panel header="Yönetici Olduğum Gruplar">
            <h:panelGrid columns="2">
                <h:outputLabel value="Grup adı: "/>
                <h:outputLabel value="#{CommunityBean.target.name}"/>
                 <h:outputLabel value="Grup Yöneticisi: "/>
                 <h:outputLabel value="#{CommunityBean.target.admin.fullName}}"/>
            </h:panelGrid>
            <p:menubar>
                <p:submenu label="Duyuru" icon="ui-icon-note">
                    <p:menuitem value="Ekle" icon="ui-icon-contact" action="#{HomePageBean.clickBoxGroupAddAnnounce()}" update="box"/>
                    <p:menuitem value="Duzenle" icon="ui-icon-refresh" action="#{HomePageBean.clickBoxGroupUpdateAnnounce()}" update="box"/>
                    <p:menuitem value="Sil" icon="ui-icon-trash" action="#{HomePageBean.clickBoxGroupDeleteAnnounce()}"  update="box"/>
                </p:submenu>
                <p:submenu label="Etkinlik" icon="ui-icon-calendar">
                    <p:menuitem value="Ekle" icon="ui-icon-contact" action="#{HomePageBean.clickBoxGroupAddEvent()}" update="box"/>
                    <p:menuitem value="Duzenle" icon="ui-icon-refresh" action="#{HomePageBean.clickBoxGroupUpdateEvent()}" update="box"/>
                    <p:menuitem value="Sil" icon="ui-icon-trash" action="#{HomePageBean.clickBoxGroupDeleteEvent()}" update="box"/>
                </p:submenu>
                <p:menuitem value="Forum" icon="ui-icon-comment" action="#{HomePageBean.clickBoxGroupForum()}" update="box"/>
                <p:menuitem value="Uyeler" icon="ui-icon-person" action="#{HomePageBean.clickBoxGroupMembers()}" update="box"/>
                <p:menuitem value="Mail Gönder" icon="ui-icon-mail-closed" action="#{HomePageBean.clickBoxGroupSendMail()}" update="box"/>
                <p:menuitem value="Grubu Kapat" icon="ui-icon-close" action="#{HomePageBean.clickBoxGroupDeleteGroup()}"   update="box"/>
            </p:menubar>
        </p:panel>
            <h:panelGrid columns="3">
                <h:panelGroup>
		    <p:panel header="Duyurular">
                        <p:dataGrid emptyMessage="Duyuru bulunmamaktadır." value="#{CommunityBean.communityAnnouncement()}" var="ann">
				<p:column>
				    <h:panelGrid columns="2">
					  <h:outputLabel value="#{ann.text}"/>
                                          <h:outputLabel value="#{CommunityBean.target.admin.fullName}"/>
				    </h:panelGrid>
				</p:column>
			  </p:dataGrid>
		    </p:panel>
		</h:panelGroup>
            </h:panelGrid>   
        </h:form>     
        
     <p:lightBox style="background: white;" id="box" visible="#{HomePageBean.box}" onHide="#{HomePageBean.makeBoxFalse()}" height="500" width="500">
	<h:outputLink value="#{HomePageBean.sayfaBox}" title="#{HomePageBean.boxTitle}"/>   
     </p:lightBox>    
        
    </body>
</html>
